package com.right.service.impl;

import com.right.dao.AdminDao;
import com.right.dao.impl.AdminDaoImpl;
import com.right.entity.Admin;

public class AdminServiceImp implements com.right.service.AdminService {
           AdminDao dao =new AdminDaoImpl();
	@Override
	public boolean login(String adminname, String adminpwd) {
	if (adminname==null||adminpwd==null) {
		return false;
	}
		return dao.login(adminname, adminpwd);
	}
	@Override
	public Admin getIdByName(String adminname) {
		if (adminname!=null) {
		return dao.getIdByName(adminname);
		}
		return null;
	}
	@Override
	public Admin getAdminByid(int adminid) {
		// TODO Auto-generated method stub
		return dao.getAdminByid(adminid);
	}
   

}
